Global Index
HTML5 JS API Index > CSS Object Model Tutorials & Specs

CSSStyleDeclaration

The CSSStyleDeclaration interface represents a CSS declaration block, including its underlying state, where this underlying state depends upon the source of the CSSStyleDeclaration instance.

Properties
DOMString_camel_cased_attribute
DOMString
cssFloat
The cssFloat attribute, on getting, must return the result of invoking getPropertyValue() with float as argument. On setting, the attribute must invoke setProperty() with float as first argument, as second argument the given value, and no third argument. Any exceptions thrown must be re-thrown.
DOMString
cssText
The cssText attribute must return the result of serializing the declarations.
unsigned long
length
The length attribute must return the number of CSS declarations in the declarations.
CSSRule?
parentRule
The parentRule attribute must return the parent CSS rule.
Operations
DOMStringgetPropertyPriority(DOMString property)
DOMStringgetPropertyValue(DOMString property)
DOMString
item(unsigned long index)
The item(index) method must return the property name of the CSS declaration at position index.
DOMStringremoveProperty(DOMString property)
voidsetProperty(DOMString property, DOMString value, optional DOMString priority)
voidsetPropertyPriority(DOMString property, DOMString priority)
voidsetPropertyValue(DOMString property, DOMString value)
Referenced by
CSSMarginRulestyle
CSSPageRulestyle
CSSStyleRulestyle
ElementCSSInlineStylestyle
GetStyleUtilsusedStyle
SVGStylablestyle
WindowgetComputedStyle(...)